import { GetanTableProps } from "../types"

/**
 * 使用操作按钮
 */
export function useToolbarActions(props: Ref<Partial<GetanTableProps>>) {
    // 左边操作按钮
    const leftActions = computed(() => unref(props).leftActions)
    // 右边操作按钮
    const rightActions = computed(() => unref(props).rightActions)

    const toolbarSlots = ["toolbarLeft", "toolbarRight"]

    return { leftActions, rightActions, toolbarSlots }
}
